import numeral from 'numeral'
interface NumeralProps {
   children: string
   format?: string
   prefix?:string
}

const Numeral = ({ format='0,0.00',prefix='', children }: NumeralProps) => {
   // numeral().format()
   if (format) {
      return <>{prefix+numeral(children).format(format)}</> 
   }
   
   return <>{children}</>
}
export default Numeral